home *** CD-ROM | disk | FTP | other *** search
/ ftp.cs.arizona.edu / ftp.cs.arizona.edu.tar / ftp.cs.arizona.edu / icon / newsgrp / group97a.txt / 000080_icon-group-sender _Wed Mar 12 10:01:04 1997.msg < prev    next >
Internet Message Format  |  2000-09-20  |  3KB

  1. Received: by cheltenham.cs.arizona.edu; Fri, 14 Mar 1997 10:39:14 MST
  2. To: icon-group@cs.arizona.edu
  3. Date: Wed, 12 Mar 1997 10:01:04 -0800
  4. From: Brian Rogoff <bpr@best.com>
  5. Message-Id: <Pine.SGI.3.95.970312094539.9196B-100000@shellx.best.com>
  6. Sender: icon-group-request@cs.arizona.edu
  7. References: <Pine.SGI.3.95.970305103012.2721A-100000@shellx.best.com>, <01bc2d80$5cac97d0$5f030514@dschauma>
  8. Subject: Modules in Icon (Was Re: Recursive directory traversal in Icon)
  9. Errors-To: icon-group-errors@cs.arizona.edu
  10. Status: RO
  11. Content-Length: 2180
  12.  
  13. Dave Schaumann wrote:
  14. > Brian Rogoff <bpr@best.com> wrote in article
  15. > <Pine.SGI.3.95.970305103012.2721A-100000@shellx.best.com>...
  16. > > Hi,
  17. > >     I've been reading the Icon web references, trying to decide if I 
  18. > > should forsake Perl in favor of Icon, and I have two questions.
  19. > > 
  20. > > (1) How do I traverse a hierarchical directory structure in Icon? I found
  21. > >     chdir, but I didn't find the equivalent of 'ls' and 'stat'. Is there 
  22. > >     a way to do this in Icon, or do you rely on the external environment?
  23. > This is one of the biggest weaknessess of Icon, especially wrt languages
  24. > like Perl -- the support for access to the OS is highly limited.  The file
  25. > IO system works pretty good, as does the extension to X.  But other than
  26. > that, about all that's available is system() and popen() (which may or may
  27. > not have a reasonable analog available on non-Un*x systems).
  28.  
  29.     As I suspected. Some people sent me system dependent solutions to 
  30. the problem, but that's not what I wanted. This is really too bad. Icon has 
  31. some terrific ideas in it, but it looks like it isn't for me.
  32.  
  33. > > (2) Why no module system?
  34. > I can't answer this directly.  However, there is Idol, which has been
  35. > described
  36. > as "Object Oriented Icon".  That's pretty much all I know about it, so I
  37. > don't
  38. > know if it supports modules.  I assume that "Object Oriented" means
  39. > inheritence,
  40. > which means classes, which means some form of encapsulation/data hiding...
  41.  
  42.     Yup, I looked at Idol. What I want are modules or packages. In *my* 
  43. religion, import is not inheritance ;-). The Eiffel heretics among you
  44. probably disagree. OTOH, an object system would be nice too, but modules
  45. are way more important. Consider that with modules, all of that system
  46. stuff like chdir and "lsdir" and "stat" could go into an Icon.File_Systems
  47. module and not pollute the global name space.
  48.  
  49. > I agree with your point, though.  Another big weakness of Icon is that
  50. > there's just too much stuff that goes in the global name space.
  51.  
  52.     Exactly the problem that modules would solve. 
  53.  
  54.     I'm beginning to think that lots of people have asked about this or 
  55. wanted it, but this isn't in the FAQ.
  56.  
  57. -- Brian
  58.  
  59.  
  60.